@extends('layouts.userctl')
@section('content')
<style>
	.formpage {
		width: 60%;
		height: auto;
		margin: 10px auto;
	}
	.layui-form-label{
		width: 150px;
	}
	.layui-input-block{
		margin-left: 150px;
	}
</style>
<div class="formpage">
	<form class="layui-form" action="{{route('admin.user.addcomuser')}}" method="post" onkeypress="return event.keyCode != 13;">
		{{csrf_field()}}
		<div class="layui-form-item">
			<label class="layui-form-label">企业名称</label>
			<div class="layui-input-block">
				<input type="text" name="qyname" required lay-verify="required" placeholder="请输入企业名称"
					class="layui-input">
			</div>
		</div>
		<div class="layui-form-item">
			<label class="layui-form-label">营业执照编号</label>
			<div class="layui-input-block">
				<input type="text" name="qycard" required lay-verify="required" placeholder="请输入营业执照编号"
					class="layui-input">
			</div>
		</div>
		<div class="layui-form-item">
			<div class="layui-input-block">
				<button class="layui-btn layui-btn-normal" lay-submit lay-filter="formDemo">立即提交</button>
				<button class="layui-btn layui-btn-primary" id="backpage">返  回</button>
			</div>
		</div>
	</form>
</div>
<script>
	//Demo
layui.use('form', function() {
	var form = layui.form
	$('#backpage').click(function() {
		history.back(-1)
	})
	//监听提交
	form.on('submit(formDemo)', function(data) {
		var index = layer.load(0, {shade:false});
	})
})
</script>

@endsection
